/*
 * @Author: liyongxuan
 * @Date: 2018-04-26 14:36:37
 * @description: 事件 --> 发行费用
*/

import Api from '../../../api/event/eventCostController.api';
import { JsonResult, EventCostDto } from '../../../api/Interface';
import { apiHttp } from '../../apiHttp';

export default {
  // 添加发行费用信息
  addSaveEventCost: async (eventCostDto: EventCostDto): Promise<JsonResult> => {
    const res: JsonResult = await apiHttp(Api.saveEventCost, eventCostDto);
    return res;
  },
  // 修改发行费用信息
  updateEventCost: async (eventCostDto: EventCostDto): Promise<JsonResult> => {
    const res: JsonResult = await apiHttp(Api.updateEventCost, eventCostDto);
    return res;
  },
  // 根据事件Id获取发行费用信息
  getEventCostDetail: async (eventId: string): Promise<JsonResult> => {
    const res: JsonResult = await apiHttp(Api.getEventCost, { eventId });
    return res;
  }
};
